package cn.gson.springmvc.model.pojos;

import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import java.util.Objects;

@Entity
public class Costsett {
    private int costsettId;
    private Integer costsettHosption;
    private String costsettNamee;
    private Integer costsettDeptotall;
    private Integer costsettDepbalancee;
    private Integer costsettRefund;
    private String costsettPersonnell;

    @Id
    @Column(name = "costsett_id", nullable = false)
    public int getCostsettId() {
        return costsettId;
    }

    public void setCostsettId(int costsettId) {
        this.costsettId = costsettId;
    }

    @Basic
    @Column(name = "costsett_hosption", nullable = true)
    public Integer getCostsettHosption() {
        return costsettHosption;
    }

    public void setCostsettHosption(Integer costsettHosption) {
        this.costsettHosption = costsettHosption;
    }

    @Basic
    @Column(name = "costsett_namee", nullable = true, length = 50)
    public String getCostsettNamee() {
        return costsettNamee;
    }

    public void setCostsettNamee(String costsettNamee) {
        this.costsettNamee = costsettNamee;
    }

    @Basic
    @Column(name = "costsett_deptotall", nullable = true, precision = 0)
    public Integer getCostsettDeptotall() {
        return costsettDeptotall;
    }

    public void setCostsettDeptotall(Integer costsettDeptotall) {
        this.costsettDeptotall = costsettDeptotall;
    }

    @Basic
    @Column(name = "costsett_depbalancee", nullable = true, precision = 0)
    public Integer getCostsettDepbalancee() {
        return costsettDepbalancee;
    }

    public void setCostsettDepbalancee(Integer costsettDepbalancee) {
        this.costsettDepbalancee = costsettDepbalancee;
    }

    @Basic
    @Column(name = "costsett_refund", nullable = true, precision = 0)
    public Integer getCostsettRefund() {
        return costsettRefund;
    }

    public void setCostsettRefund(Integer costsettRefund) {
        this.costsettRefund = costsettRefund;
    }

    @Basic
    @Column(name = "costsett_personnell", nullable = true, length = 30)
    public String getCostsettPersonnell() {
        return costsettPersonnell;
    }

    public void setCostsettPersonnell(String costsettPersonnell) {
        this.costsettPersonnell = costsettPersonnell;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        Costsett costsett = (Costsett) o;
        return costsettId == costsett.costsettId &&
                Objects.equals(costsettHosption, costsett.costsettHosption) &&
                Objects.equals(costsettNamee, costsett.costsettNamee) &&
                Objects.equals(costsettDeptotall, costsett.costsettDeptotall) &&
                Objects.equals(costsettDepbalancee, costsett.costsettDepbalancee) &&
                Objects.equals(costsettRefund, costsett.costsettRefund) &&
                Objects.equals(costsettPersonnell, costsett.costsettPersonnell);
    }

    @Override
    public int hashCode() {
        return Objects.hash(costsettId, costsettHosption, costsettNamee, costsettDeptotall, costsettDepbalancee, costsettRefund, costsettPersonnell);
    }
}
